package com.icongyou.enterprise.talent_marking.mapper;

import com.icongyou.enterprise.talent_marking.entity.vo.StudentBasicInfo;
import com.icongyou.enterprise.talent_marking.entity.vo.StudentFocusMark;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface StudentFocusMarkMapper {
    //检查是否已经存在标记
    StudentFocusMark selectByUserAndStudent(@Param("userId") String userId,
                                            @Param("studentId") String studentId);

    //更新现有标记
    void updateById(StudentFocusMark existingMark);

    //插入标记
    void insert(StudentFocusMark newMark);

    //删除标记
    void deleteByUserAndStudent(@Param("userId") String userId,
                                @Param("studentId") String studentId);

    //根据用户ID获取所有关注学生
    List<StudentFocusMark> selectByUserId(String userId);

    List<StudentBasicInfo> selectFocusStudentInfoByUserId(@Param("userId") String userId);
}
